SUPPORT / SAMPLES & SAS NOTES
 

Support

Problem Note 46767: A loop occurs upon termination of SAS® 9.3 if autocall macros have been processed

DetailsCodeAboutRate It

In SAS 9.3, a loop might occur during termination of SAS if any autocall SAS macros had been processed during the session. The problem occurs when all of the following conditions exist:

  • A file was allocated externally to SAS, such as in a Job Control Language (JCL) data definition (DD) statement.

  • A FILENAME statement in the SAS program used the same DD name that was defined externally.

  • The same files must have been allocated in the same order in both the external allocation and the FILENAME statement, with at least one additional file in the FILENAME statement at the beginning of the concatenation.

  • The SAS system option SASAUTOS being set and making reference to the fileref/ddname.

  • SAS macro autocall services were used subsequent to setting the SAS system option SASAUTOS.

When you terminate SAS during resource cleanup, SAS loops while trying to clear the SASAUTOS DD name. The SASLOG displays SAS termination messages, and all output is complete, but the job is still consuming CPU time.

If all of the above conditions are true except that the data set names are different or the order is different, then instead of the loop during termination, you get the following error in your SAS log:

      ERROR: Logical name MYAUTOS assigned but not in current scope.
      ERROR: Error in the FILENAME statement.

Click the Full Code tab for a simple example that illustrates the setup that causes this looping condition.

To circumvent this problem, remove either the external or internal allocation for the user autocall library.



Operating System and Release Information

Product FamilyProductSystemSAS Release
ReportedFixed*
SAS SystemBase SASz/OS9.3 TS1M09.4 TS1M0
* For software releases that are not yet generally available, the Fixed Release is the software release in which the problem is planned to be fixed.